package org.ifilm.service;

import java.util.List;

import org.ifilm.model.EquipmentOffer;
import org.ifilm.model.EquipmentPosting;
import org.ifilm.model.JobApplication;
import org.ifilm.model.Project;
import org.ifilm.model.UserJobPosting;

/**
 * Notice Service interface
 * 
 * @author Mustafa Genc
 *
 */
public interface NoticeService {
	/**
	 * 
	 * @param jobPosting
	 * 		job posting to persist
	 * @return
	 * 		created job posting that has merged
	 */
	public UserJobPosting createJobPosting(UserJobPosting jobPosting);
	
	public EquipmentPosting createEquipmentPosting(EquipmentPosting equipmentPosting);
	
	/**
	 * 
	 * @param user
	 * 		posting owner
	 * @return
	 * 		posting list
	 */
	public List<UserJobPosting> listJobPostings();
	
	public void editJobPosting(UserJobPosting jobPosting);
	
	public void updateProjectPostings(Project project, List<UserJobPosting> userJobPostings, List<EquipmentPosting> equipmentPostings);
	
	public UserJobPosting getUserJobPosting(Long id);
	
	public EquipmentPosting getUserEquipmentPosting(Long id);
	
	public JobApplication createJobApplication(JobApplication jobApplication);
	
	public EquipmentOffer createEquipmentOffer(EquipmentOffer equipmentOffer);
	
	public void updateJobPostingAppliances(UserJobPosting userJobPosting, JobApplication jobApplication);
	
	public void updateEquipmentOffers(EquipmentPosting equipmentPosting, EquipmentOffer equipmentOffer);
	
	public List<JobApplication> getJobApplications(Long userId);
	
	public void updateJobApplication(JobApplication jobApplication);

	public JobApplication getJobApplicationById(Long jobApplicationId);

	public List<EquipmentOffer> getEquipmentOffers(Long userId);

	public void deleteJobPosting(UserJobPosting jobPosting);
}